package com.doone.telmarket.domain;

import java.io.Serializable;
import java.math.BigDecimal;

import com.doone.telmarket.domain.ibator.ServiceClassify;
import com.doone.telmarket.domain.ibator.ServiceType;

/**
 * 
 * @author 吴同庆
 * @date 2009-9-14
 * @description 增值业务实体
 * @package     com.doone.telmarket.domain
 */
public class Service implements Serializable{
	
	private static final long serialVersionUID = 5789933126886899487L;

	//增值业务编码
	private String serviceCode;
	
	//增值业务编码类型
	private ServiceCodeType serviceCodeType;
	
	//增值业务名称
	private String serviceName;
	
	//增值业务摘要
	private String serviceSummary;
	
	//增值业务使用费用
	private Currency serviceCost;
	
	//SP厂商名称
	private String spName;
	
	//增值业务状态
	private ServiceState serviceState;
	
	//增值业务类型
	private ServiceType serviceType;
	
	//增值业务类别
	private ServiceClassify serviceClassify;
	
	
	public Service(){
		
	}
	
	public Service(String serviceCode,String serviceCodeType,String serviceName
					,String serviceSummary,Currency serviceCost,String spName,String serviceState
					,ServiceType serviceType,ServiceClassify serviceClassify){
		this.serviceCode = serviceCode;
		this.serviceCodeType = ServiceCodeType.valueOf(serviceCodeType);
		this.serviceName = serviceName;
		this.serviceSummary = serviceSummary;
		this.serviceCost = serviceCost;
		this.spName = spName;
		this.serviceState = ServiceState.valueOf(serviceState);
		this.serviceType = serviceType;
		this.serviceClassify = serviceClassify;
		
	}
	
	public Integer getServiceTypeId(){
		return getServiceType().getServiceTypeId();
	}
	
	public String getServiceTypeName(){
		return getServiceType().getServiceTypeName();
	}
	
	public Integer getServiceClassifyId(){
		return getServiceClassify().getServiceClassifyId();
	}
	
	public String getServiceClassifyName(){
		return getServiceClassify().getServiceClassifyName();
	}

	public String getServiceCode() {
		return serviceCode;
	}

	public void setServiceCode(String serviceCode) {
		this.serviceCode = serviceCode;
	}

	public ServiceCodeType getServiceCodeType() {
		return serviceCodeType;
	}

	public void setServiceCodeType(ServiceCodeType serviceCodeType) {
		this.serviceCodeType = serviceCodeType;
	}

	public String getServiceName() {
		return serviceName;
	}

	public void setServiceName(String serviceName) {
		this.serviceName = serviceName;
	}

	public String getServiceSummary() {
		return serviceSummary;
	}

	public void setServiceSummary(String serviceSummary) {
		this.serviceSummary = serviceSummary;
	}

	public Currency getServiceCost() {
		return serviceCost;
	}
	
	public BigDecimal getServiceCostMoney(){
		return serviceCost.getMoney();
	}

	public void setServiceCost(Currency serviceCost) {
		this.serviceCost = serviceCost;
	}

	public String getSpName() {
		return spName;
	}

	public void setSpName(String spName) {
		this.spName = spName;
	}

	public ServiceState getServiceState() {
		return serviceState;
	}

	public void setServiceState(ServiceState serviceState) {
		this.serviceState = serviceState;
	}

	public ServiceType getServiceType() {
		return serviceType;
	}

	public void setServiceType(ServiceType serviceType) {
		this.serviceType = serviceType;
	}

	public ServiceClassify getServiceClassify() {
		return serviceClassify;
	}

	public void setServiceClassify(ServiceClassify serviceClassify) {
		this.serviceClassify = serviceClassify;
	}
	
	
	
	
	

}
